var http = require('http');
var url = require('url');

// 获取get请求传递过来的参数
http.createServer(function(req,res){
  res.writeHead(200,{'Content-Type':'text/plain'});
  var query = url.parse(req.url, true).query;
  res.write('名字：'+query.name+'\n');
  res.write('数据：'+query.data+'\n');
  res.end();
}).listen(8888);
